Optimal. Leaf size=96 \[ \frac{(d+e x)^3 \left (a+b \tanh ^{-1}(c x)\right )}{3 e}-\frac{b (c d-e)^3 \log (c x+1)}{6 c^3 e}+\frac{b (c d+e)^3 \log (1-c x)}{6 c^3 e}+\frac{b d e x}{c}+\frac{b e^2 x^2}{6 c} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.121853, antiderivative size = 96, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 4, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.25, Rules used = {5926, 702, 633, 31} \[ \frac{(d+e x)^3 \left (a+b \tanh ^{-1}(c x)\right )}{3 e}-\frac{b (c d-e)^3 \log (c x+1)}{6 c^3 e}+\frac{b (c d+e)^3 \log (1-c x)}{6 c^3 e}+\frac{b d e x}{c}+\frac{b e^2 x^2}{6 c} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 5926
Rule 702
Rule 633
Rule 31
Rubi steps
\begin{align*} \int (d+e x)^2 \left (a+b \tanh ^{-1}(c x)\right ) \, dx &=\frac{(d+e x)^3 \left (a+b \tanh ^{-1}(c x)\right )}{3 e}-\frac{(b c) \int \frac{(d+e x)^3}{1-c^2 x^2} \, dx}{3 e}\\ &=\frac{(d+e x)^3 \left (a+b \tanh ^{-1}(c x)\right )}{3 e}-\frac{(b c) \int \left (-\frac{3 d e^2}{c^2}-\frac{e^3 x}{c^2}+\frac{c^2 d^3+3 d e^2+e \left (3 c^2 d^2+e^2\right ) x}{c^2 \left (1-c^2 x^2\right )}\right ) \, dx}{3 e}\\ &=\frac{b d e x}{c}+\frac{b e^2 x^2}{6 c}+\frac{(d+e x)^3 \left (a+b \tanh ^{-1}(c x)\right )}{3 e}-\frac{b \int \frac{c^2 d^3+3 d e^2+e \left (3 c^2 d^2+e^2\right ) x}{1-c^2 x^2} \, dx}{3 c e}\\ &=\frac{b d e x}{c}+\frac{b e^2 x^2}{6 c}+\frac{(d+e x)^3 \left (a+b \tanh ^{-1}(c x)\right )}{3 e}+\frac{\left (b (c d-e)^3\right ) \int \frac{1}{-c-c^2 x} \, dx}{6 c e}-\frac{\left (b (c d+e)^3\right ) \int \frac{1}{c-c^2 x} \, dx}{6 c e}\\ &=\frac{b d e x}{c}+\frac{b e^2 x^2}{6 c}+\frac{(d+e x)^3 \left (a+b \tanh ^{-1}(c x)\right )}{3 e}+\frac{b (c d+e)^3 \log (1-c x)}{6 c^3 e}-\frac{b (c d-e)^3 \log (1+c x)}{6 c^3 e}\\ \end{align*}
Mathematica [A] time = 0.0953217, size = 129, normalized size = 1.34 \[ \frac{1}{6} \left (\frac{e x^2 (6 a c d+b e)}{c}+\frac{6 d x (a c d+b e)}{c}+2 a e^2 x^3+\frac{b \left (3 c^2 d^2+3 c d e+e^2\right ) \log (1-c x)}{c^3}+\frac{b \left (3 c^2 d^2-3 c d e+e^2\right ) \log (c x+1)}{c^3}+2 b x \tanh ^{-1}(c x) \left (3 d^2+3 d e x+e^2 x^2\right )\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.029, size = 218, normalized size = 2.3 \begin{align*}{\frac{a{x}^{3}{e}^{2}}{3}}+a{x}^{2}de+ax{d}^{2}+{\frac{a{d}^{3}}{3\,e}}+{\frac{b{e}^{2}{\it Artanh} \left ( cx \right ){x}^{3}}{3}}+be{\it Artanh} \left ( cx \right ){x}^{2}d+b{\it Artanh} \left ( cx \right ) x{d}^{2}+{\frac{b{\it Artanh} \left ( cx \right ){d}^{3}}{3\,e}}+{\frac{b{e}^{2}{x}^{2}}{6\,c}}+{\frac{bdex}{c}}+{\frac{b\ln \left ( cx-1 \right ){d}^{3}}{6\,e}}+{\frac{b\ln \left ( cx-1 \right ){d}^{2}}{2\,c}}+{\frac{be\ln \left ( cx-1 \right ) d}{2\,{c}^{2}}}+{\frac{b{e}^{2}\ln \left ( cx-1 \right ) }{6\,{c}^{3}}}-{\frac{b\ln \left ( cx+1 \right ){d}^{3}}{6\,e}}+{\frac{b\ln \left ( cx+1 \right ){d}^{2}}{2\,c}}-{\frac{be\ln \left ( cx+1 \right ) d}{2\,{c}^{2}}}+{\frac{b{e}^{2}\ln \left ( cx+1 \right ) }{6\,{c}^{3}}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 0.989791, size = 185, normalized size = 1.93 \begin{align*} \frac{1}{3} \, a e^{2} x^{3} + a d e x^{2} + \frac{1}{2} \,{\left (2 \, x^{2} \operatorname{artanh}\left (c x\right ) + c{\left (\frac{2 \, x}{c^{2}} - \frac{\log \left (c x + 1\right )}{c^{3}} + \frac{\log \left (c x - 1\right )}{c^{3}}\right )}\right )} b d e + \frac{1}{6} \,{\left (2 \, x^{3} \operatorname{artanh}\left (c x\right ) + c{\left (\frac{x^{2}}{c^{2}} + \frac{\log \left (c^{2} x^{2} - 1\right )}{c^{4}}\right )}\right )} b e^{2} + a d^{2} x + \frac{{\left (2 \, c x \operatorname{artanh}\left (c x\right ) + \log \left (-c^{2} x^{2} + 1\right )\right )} b d^{2}}{2 \, c} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.66562, size = 358, normalized size = 3.73 \begin{align*} \frac{2 \, a c^{3} e^{2} x^{3} +{\left (6 \, a c^{3} d e + b c^{2} e^{2}\right )} x^{2} + 6 \,{\left (a c^{3} d^{2} + b c^{2} d e\right )} x +{\left (3 \, b c^{2} d^{2} - 3 \, b c d e + b e^{2}\right )} \log \left (c x + 1\right ) +{\left (3 \, b c^{2} d^{2} + 3 \, b c d e + b e^{2}\right )} \log \left (c x - 1\right ) +{\left (b c^{3} e^{2} x^{3} + 3 \, b c^{3} d e x^{2} + 3 \, b c^{3} d^{2} x\right )} \log \left (-\frac{c x + 1}{c x - 1}\right )}{6 \, c^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 2.03709, size = 178, normalized size = 1.85 \begin{align*} \begin{cases} a d^{2} x + a d e x^{2} + \frac{a e^{2} x^{3}}{3} + b d^{2} x \operatorname{atanh}{\left (c x \right )} + b d e x^{2} \operatorname{atanh}{\left (c x \right )} + \frac{b e^{2} x^{3} \operatorname{atanh}{\left (c x \right )}}{3} + \frac{b d^{2} \log{\left (x - \frac{1}{c} \right )}}{c} + \frac{b d^{2} \operatorname{atanh}{\left (c x \right )}}{c} + \frac{b d e x}{c} + \frac{b e^{2} x^{2}}{6 c} - \frac{b d e \operatorname{atanh}{\left (c x \right )}}{c^{2}} + \frac{b e^{2} \log{\left (x - \frac{1}{c} \right )}}{3 c^{3}} + \frac{b e^{2} \operatorname{atanh}{\left (c x \right )}}{3 c^{3}} & \text{for}\: c \neq 0 \\a \left (d^{2} x + d e x^{2} + \frac{e^{2} x^{3}}{3}\right ) & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.15238, size = 263, normalized size = 2.74 \begin{align*} \frac{b c^{3} x^{3} e^{2} \log \left (-\frac{c x + 1}{c x - 1}\right ) + 3 \, b c^{3} d x^{2} e \log \left (-\frac{c x + 1}{c x - 1}\right ) + 2 \, a c^{3} x^{3} e^{2} + 6 \, a c^{3} d x^{2} e + 3 \, b c^{3} d^{2} x \log \left (-\frac{c x + 1}{c x - 1}\right ) + 6 \, a c^{3} d^{2} x + b c^{2} x^{2} e^{2} + 6 \, b c^{2} d x e + 3 \, b c^{2} d^{2} \log \left (c^{2} x^{2} - 1\right ) - 3 \, b c d e \log \left (c x + 1\right ) + 3 \, b c d e \log \left (c x - 1\right ) + b e^{2} \log \left (c^{2} x^{2} - 1\right )}{6 \, c^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]